<?php 
/**
 * 
 * 美容院 处理类
 * @author tanzhe
 *
 */
class salon {
	
	public function get() { //获得美容院项目
		$url = new Url();
		$shopId = $url->get('shopid');
	  	$key = $url->get('key');
		$salonModel = new SalonModel(); 
		$ret = $salonModel->getSalon($key, $shopId);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function save() { //保存美容信息
		$url = new Url();
		$type = $url->get('type');
	  	$key = $url->get('key');
		$style = $url->get('style');
		$color = $url->get('color');
		$skin = $url->get('skin');
		$friendId = $url->get('friend_id');
		$salonModel = new SalonModel();
		$ret = $salonModel->saveSalon($key, $type, $style, $color, $skin, $friendId);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}	
}
?>